package com.geeker.module.sys.log.domain;

import com.fasterxml.jackson.annotation.JsonFormat;
import com.geeker.common.annotation.Excel;
import com.mybatisflex.annotation.Id;
import io.swagger.v3.oas.annotations.media.Schema;
import lombok.Data;

import java.util.Date;

@Data
@Schema(description = "登录日志记录表")
public class SysLogLogin {

    @Id
    @Excel(name = "序号", cellType = Excel.ColumnType.NUMERIC)
    private Long infoId;

    @Schema(description = "用户账号")
    @Excel(name = "用户账号")
    private String userName;

    @Schema(description = "登录状态")
    @Excel(name = "登录状态", readConverterExp = "0=成功,1=失败")
    private String status;

    @Schema(description = "登录地址")
    @Excel(name = "登录地址")
    private String ipaddr;

    @Schema(description = "登录地点")
    @Excel(name = "登录地点")
    private String loginLocation;

    @Schema(description = "浏览器类型")
    @Excel(name = "浏览器")
    private String browser;

    @Schema(description = "操作系统")
    @Excel(name = "操作系统")
    private String os;

    /** 提示消息 */
    @Excel(name = "提示消息")
    private String msg;

    /** 访问时间 */
    @JsonFormat(pattern = "yyyy-MM-dd HH:mm:ss")
    @Excel(name = "访问时间", width = 30, dateFormat = "yyyy-MM-dd HH:mm:ss")
    private Date loginTime;
}
